
/**
 *  \file obex_fsm_api.c
 *
 *  This file implements the API for OBEX using FSM
 */

/*
 *  Copyright (C) 2011. MindTree Ltd.
 *  All rights reserved.
 */

/* ----------------------------------------------- Header File Inclusion */
#include "obex_internal.h"
#include "obex_extern.h"
#include "obex_fsm_engine.h"

/* --------------------------------------------- External Global Variables */

/* --------------------------------------------- Exported Global Variables */

/* --------------------------------------------- Static Global Variables */

/* --------------------------------------------- Functions */

API_RESULT obex_get_event_id (UCHAR *event_id,
                             OBEX_SESSION * obex_session,
                             UCHAR result);

API_RESULT obex_packet_read_callback
           (
               /* IN */  UCHAR count,
               /* IN */  UINT16 result,
               /* IN */  UCHAR * data,
               /* IN */  UINT16 datalen,
               /* OUT */ UINT16 *consumed
           );

void obex_copy_obj_hdrs (UCHAR *buffer,
                         OBEX_OBJ_HEADER * obj_hdr,
                         UINT16 num_of_hdrs);

API_RESULT obex_send_packet (OBEX_HANDLE obex_handle,
                             OBEX_SESSION *obex_session,
                             OBEX_OBJ_HEADER *obj_hdrs,
                             UINT16 num_of_hdrs);

API_RESULT obex_extract_pkt_hdr (OBEX_SESSION *obex_session,
                                 UCHAR **obex_data,
                                 UINT16 *data_len);

void obex_append_srm_hdr (OBEX_OBJ_HEADER  *dest_obj_hdrs,
                          OBEX_OBJ_HEADER  *src_obj_hdrs,
                          UINT16          num_of_hdrs);

void obex_get_srm_hdr (UCHAR    *data,
                       UINT16   datalen,
                       UCHAR    *srm_hdr_id,
                       UCHAR    *srm_hdr_value);

